package poker;

import java.util.ArrayList;
import java.util.List;

public class Game {

    public static void main(String[] args) {
        int num=4;//四名玩家
        List<poker> pokersList = new ArrayList<poker>();//扑克牌牌组
        List<Player> players=new ArrayList<Player>();

        Pokers pokers = new Pokers();
        pokersList=pokers.getPokersList();

        //创建玩家
        for (int i=0;i<num;i++){
            Player p = new Player();
            p.setId(i);
            players.add(p);
        }

        int i=0;
        for (poker p:pokersList) {
            if (i==4){i=0;}
            players.get(i).setPlayerPokers(p);
            i++;
        }
        for (int pId=0;pId<num;pId++){
            System.out.print("玩家：ID:"+pId+"  牌组为：");
            players.get(pId).show();
            System.out.println("");
        }
    }
}
